package com.yunao.commons.utils;

import esoucfg.DomainTrans;

public class DomainSourceUtils {

	public static String getSource(String key) {
		DomainTrans t = DomainTrans.getInstance();
		return t.parseEn(key);
	}

	public static String getSource(String key, String defaultValue) {
		DomainTrans t = DomainTrans.getInstance();
		String value = t.parseEn(key);
		if (key.equals(value)) value = defaultValue;
		return value;
	}

	public static String[] getDomain(String source) {
		DomainTrans t = DomainTrans.getInstance();
		return t.parseZn(source);
	}

}
